<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset={$_K['charset']}" />
<title>left</title>
</head>
<link href="tpl/css/style.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="tpl/js/jquery.js">
        </script>
<body bgcolor="#EBEBEB">
<div class="left">
	<dl>
		
		<!--{eval $i = 0;}-->
		{loop $urlset_arr $key $set}
		<dt style="cursor:pointer;" {if $t_set_arr}class="nav_1"{else}class="nav_2"{/if} id='dt'><strong>{$set['name']}</strong></dt>
		<dd id="submenu_id_{$set['submenu_id']}" style="display:none;">
			{loop $set[items] $item}
			{if $admin_info['uid']==ADMIN_UID||in_array($item[resource_id],$group_arr[$admin_info[group_id]][group_roles])}<a href="{$item['resource_url']}" id="a_item_{$i}" onclick="selectitem(this,'{$set['name']}')" target="main">{$item['resource_name']}</a>
			<!--{eval $i++;$t_set_arr = $t_set_arr?$t_set_arr:$set}-->{/if}
			{/loop}
		</dd>
		{/loop}
		
	</dl>
</div>
<script>
	$(function(){
	   var count = 0;
	     $("dl>dt").click(function(){
		 	  $(this).next().slideToggle("slow");
			  if($(this).hasClass("nav_2")){
			  	 $(this).removeClass("nav_2");
				 $(this).addClass("nav_1");
			  }else{
			  	 $(this).removeClass("nav_1");
				 $(this).addClass("nav_2");
			  }
		 })
		 {if $opnew}
		 var a_op_c = document.getElementById('a_item_0');
		 parent.main.location.href = a_op_c.href;
		 parent.document.getElementById("nav3").innerHTML=a_op_c.innerHTML;
		 parent.document.getElementById("nav2").innerHTML='{$t_set_arr[name]}';
		 parent.document.getElementById("nav1").innerHTML='{$menu_arr[$menu]}';
		 //$('#submenu_id_{$t_set_arr[submenu_id]}').last().removeClass("nav_1");
		 //$('#submenu_id_{$t_set_arr[submenu_id]}').last().addClass("nav_2");
		 {/if}
		 $('#submenu_id_{$t_set_arr[submenu_id]}').show("slow");
		})
	function selectitem(item,submenuname){
		var ii=0;
		for(ii=0;ii<{$i};ii++){
			
			if(document.getElementById('a_item_'+ii).className =='isself')
			{
				document.getElementById('a_item_'+ii).className ='';
			}
		}
		item.className="isself";
		parent.document.getElementById("nav3").innerHTML=item.innerHTML;
		parent.document.getElementById("nav2").innerHTML=submenuname;
		parent.document.getElementById("nav1").innerHTML='{$menu_arr[$menu]}';
	}
</script>
</body>
</html>